1. Field of the Invention
This invention relates generally to data processing systems and, more particularly, to events that can cause a change in the program under execution in a data processing system.
2. Description of the Related Art
In modern high performance data processing systems, the processing capability is sufficient to permit a multiplicity of activities to be carried on concurrently. Without the concurrency of activities, the resources of the data processing system would be under-utilized. A control program is typically required to schedule the resources of the data processing system and provide program execution among a set of system users. The control program is provided with the capability of suspending the execution of a program by saving the state of parameters of a resource (such as a data processing unit), permitting another program to utilize the resource and then restoring the resource states or parameters, and continuing execution of the suspended program. In this manner, resources can be multiplexed with respect to a plurality of system users and/or programs. The control program is responsible for maintaining the activity of the data processing system at as high a level as possible consistent with an equitable allocation of the system resources among the potential candidates for use of the resources.
While an activity is being executed in response to the current program, the interruption of the executing activity can be necessary to respond to events that occur outside the cognizance of the control program. The currently executing program must therefore be notified that an external activity has a requirement for the resource. Exemplary of external events requiring a resource in current use can be completion of an input/output (I/O) request, an interruption generated by another program (e.g., a program signal), a terminal user interrupting the program by means of a keyboard of other device for entering a signal by a system user or by the control program itself to notify the program of asynchronous events (e.g., an expired timer). These events are typically referred to as AST (Asynchronous System Trap) events. Indeed, the control program can have a need to interrupt an executing program to execute part of the control program itself in the context of the appropriate program (e.g., posting I/O completion of transfer data groups from internal buffers to program buffers, etc.). However, the interruption of a program at a given time can be inappropriate and lead to the compromise of critical data.
In the related data processing systems, the capabilities required for program interruption have been implemented in the control program itself. The control program implementation of program interruption require high overhead costs in the form of processing capability utilization and, in addition, require that certain events must be continually monitored. Each time a monitored event is detected, the control program must test related conditions to determine if the currently executing program is to be interrupted to execute the interruption program. Moreover, the currently executing program must be able to inform the control program that it cannot be interrupted at the present time. Finally, if the program interrupts or attempts to interrupt are frequent, then an unacceptable amount of the processing capability can used in the control program.
A need has therefore been felt for apparatus and method to control program interrupts that is directly available to nonprivileged programs and which do not contain the inefficiencies involved in a software program implementation.